public class Salary extends Employee {
    private double salary;
    public Salary(String name,String address,int number,double salary)
    {
        super(name,address,number);
        setSalary(salary);
    }
    @Override
    public void mailCheck()
    {
        System.out.println("Salary类的mailCheck方法");
        System.out.println("邮票支票给："+this.getName()+" ，工资为： "+this.salary);
    }
    public double getSalary()
    {
        return salary;
    }
    public void setSalary(double newSalary)
    {
        if(newSalary>=0.0)
        {
            salary=newSalary;
        }
    }
    public double computerPay(){
        System.out.println("计算工资，付给："+getName());
        return salary/52;
    }

}